const axios = require('axios')
let _baseUrl = '/gateway/images/api'

// 获取公开数据集
export function getImageList () {
  const url = _baseUrl + '/imagesInfo'
  return axios.get(url).then((res) => {
    return Promise.resolve(res.data)
  })
}

// 获取框架列表
export function frameworkGetList () {
  const url = _baseUrl + '/framework/getList'
  return axios.get(url).then((res) => {
    return Promise.resolve(res.data)
  })
}

// 获取编程语言列表
export function languageGetList () {
  const url = _baseUrl + '/language/getList'
  return axios.get(url).then((res) => {
    return Promise.resolve(res.data)
  })
}

// 获取镜像列表
export function imagesGetList (query) {
  const url = _baseUrl + '/images/getList' + query
  return axios.get(url).then((res) => {
    return Promise.resolve(res.data)
  })
}
